<template>
	<view>
		<uni-titles :title="'物联监测'"></uni-titles>
		<uni-tudwhere></uni-tudwhere>
		<uni-farmtitle :title="'物联设备'" :num="'22'" serchShow @isshow="show = !show"></uni-farmtitle>
		<uni-serchs v-if="show"></uni-serchs>
		<view>
			<view class="monitorbox">
				<view class="item" v-for="(d,index) in list" :key="d.name">
					<u--image :mode="'aspectFill'" :src="d.img" width="120rpx" height="100rpx"></u--image>
					<view class="rightcontent">
						<view class="fs-24 title">
							<view>
								<text>{{ d.name }}</text>
								<text v-if="d.type == 0" class="text3 fs-24" :class="'type'+d.type">未运行</text>
								<text v-else="d.type == 1" class="text3 fs-24" :class="'type'+d.type">运行中</text>
							</view>
						</view>
						<view class="fs-24 mar-top24">{{ d.text }}</view>
					</view>
				</view>
			</view>
		</view>
		<uni-more></uni-more>
	</view>
</template>

<script>
	export default {
		
		data() {
			return {
				show:false,
				list:[
					{img: 'https://t7.baidu.com/it/u=1595072465,3644073269&fm=193&f=GIF',name:'土壤养分速测仪',text:'对土壤养分进行分析',type:0},
					{img: 'https://t7.baidu.com/it/u=1595072465,3644073269&fm=193&f=GIF',name:'土壤养分速测仪',text:'对土壤养分进行分析',type:1},
					{img: 'https://t7.baidu.com/it/u=1595072465,3644073269&fm=193&f=GIF',name:'土壤养分速测仪',text:'对土壤养分进行分析',type:1},
					{img: 'https://t7.baidu.com/it/u=1595072465,3644073269&fm=193&f=GIF',name:'土壤养分速测仪',text:'对土壤养分进行分析',type:1},
					{img: 'https://t7.baidu.com/it/u=1595072465,3644073269&fm=193&f=GIF',name:'土壤养分速测仪',text:'对土壤养分进行分析',type:1}
				]
			};
		}
	}
</script>

<style lang="scss">
page{
	background: #f6f6f6;
	padding-bottom: 20rpx;
}
.monitorbox {
	margin: 20rpx 30rpx 0;
	.item {
		display: flex;
		background: #fff;
		margin-top: 20rpx;
		padding: 14rpx 18rpx 16rpx;
		border-radius: 8rpx;
		.rightcontent {
			flex: 1;
			margin-left: 16rpx;
			align-items: center;
			.title {
				display: flex;
				justify-content: space-between;
				align-items: center;
				.text3 {
					border: 1px solid #10b9ff;
					background: #eaf9ff;
					color: #13b3ee;
					border-radius: 8rpx;
					padding: 0 10rpx;
					margin-left: 16rpx;
				}
				.type0{
					border: 1px solid #FEA211;
					background: #FFEAD4;
					color: #FEA211;
				}
			}
		}
	}
}
</style>
